﻿package com.bluediesel.utils.managers.scenemanager.commands.events {
	import com.bluediesel.utils.managers.scenemanager.commands.Command;
	
	import flash.events.IEventDispatcher;
	
	//this command encapsulates the removeEventListener() method
	public class RemoveEventListener extends Command {
		
		public var type:String;
		public var listener:Function;
		
		public function RemoveEventListener(obj:Object, type:String, listener:Function) {
			super(obj);
			this.type = type;
			this.listener = listener;
		}
		
		override protected function execute(obj:Object = null):void {
			obj.removeEventListener(type, listener);
		}
	}
}